import Mock from "mockjs";
import qs from "qs";

export default () => {

  // 菜单获取
  Mock.mock(/\/menu/, {
    data: [
      {
        path: "/",
        name: "面板",
        icon: "md-speedometer",
        compName: "面板",
        compPath: "/dashboard"
      },
      {
        path: "/test",
        name: "Test",
        icon: "md-document",
        compName: "Test",
        compPath: "/dashboard"
      },
      {
        path: "/auth",
        name: "权限管理",
        icon: "md-chatbubbles",
        children: [
          {
            path: "/auth/domains",
            name: "域",
            icon: "md-text",
            compName: "domains",
            compPath: "/auth/domains"
          },
          {
            path: "/auth/account",
            name: "成员",
            icon: "md-text",
            compName: "account",
            compPath: "/auth/account"
          },
          {
            path: "/auth/roles",
            name: "角色",
            icon: "md-text",
            compName: "roles",
            compPath: "/auth/roles"
          },
          {
            path: "/auth/menu",
            name: "菜单",
            icon: "md-text",
            compName: "menu",
            compPath: "/auth/menu"
          }
        ]
      },
      {
        path: "/manage",
        name: "Manage",
        icon: "md-folder-open",
        children: [
          {
            path: "/manage/users",
            name: "Users",
            icon: "md-people",
            compName: "Users",
            compPath: "/manage/users"
          }
        ]
      }


    ],
    error: {
      code: 0,
      msg: "Get menu success"
    }
  });

};
